package org.lib.rabbitmqhello.try3;

import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

import lombok.extern.slf4j.Slf4j;

@Component
@Slf4j
public class Try3Listener {

	/**
	 * Listener1
	 * @author ben
	 * @date 2021-08-23 22:31:58 CST
	 * @param content
	 */
	@RabbitListener(queues = {RabbitConfig3.QUEUE_31})
	public void processMessage31(String content) {
		log.info("接收消息：队列{}-processMessage31-content={}", 
				RabbitConfig3.QUEUE_31, content);
	}
	
	/**
	 * Listener2
	 * @author ben
	 * @date 2021-08-27 21:26:30 CST
	 * @param content
	 */
	@RabbitListener(queues = {RabbitConfig3.QUEUE_32})
	public void processMessage32(String content) {
		log.info("接收消息：队列{}-processMessage32-content={}", RabbitConfig3.QUEUE_32, content);
	}
	
}
